package service;

import java.util.List;

import dao.DepartDao;
import entity.Depart;

public class DepartService {

	
	public void save(Depart depart) {
		DepartDao dao = new DepartDao();
		dao.save(depart);
	}
	
	public void update(Depart depart) {
		DepartDao dao = new DepartDao();
		dao.update(depart);
	}
	
	
	public void delete(String id) {
		DepartDao dao = new DepartDao();
		dao.delete(id);
	}
	
	
	public Depart findById(String id) {
		DepartDao dao = new DepartDao();
		return  dao.findById(id);
	}
	
	public List<Depart> findAll() {
		DepartDao dao = new DepartDao();
		return dao.findAll();
	}
	
}
